﻿if (typeof (dxrApp) === 'undefined')
    dxrApp = angular.module('dxr.controls', []);

dxrApp.directive('onRepeatFinish', function ($timeout) {
    return {
        restrict: 'A',
        link: function (scope, element, attr) {
            if (scope.$last === true) {
                $timeout(function () {
                    scope.$emit('onRepeatFinish', attr.datatarget);
                });
            }
        }
    };
});
